package com.company;

import javax.swing.*;
import java.awt.*;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;

class Menu extends JFrame {
    public Menu()
    {
        this.setBounds(300, 150, 500, 450);
        this.setTitle("烟台大学 -- --学生信息管理系统");
        this.setLayout(null);
        JLabel labTipw = new JLabel("欢迎进入 烟台大学 学生信息管理系统");
        labTipw.setBounds(50, 2, 250, 45);
        JLabel labTipws = new JLabel("（*新用户初始密码为  身份证后六位数字）");
        labTipws.setBounds(50, 15, 250, 45);
        JLabel labyonghu = new JLabel("用户名:");
        labyonghu.setBounds(50, 60, 100, 50);
        JTextField txtyonghu = new JTextField("请输入登录用户名：",30);
        txtyonghu.setBounds(130, 76, 180, 30);
        JLabel  labmima = new JLabel("密码：");
        labmima.setBounds(50, 100, 50, 50);
        JTextField txtmima = new JTextField("请输入登录6位密码：",30);
        txtmima.setBounds(130, 117, 180, 30);
        JButton btndianji = new JButton("点击登录");
        btndianji.setBounds(130, 165, 180, 30);
        btndianji.setForeground(Color.BLUE);

        this.add(labTipw);
        this.add(labTipws);
        this.add(labyonghu);
        this.add(txtyonghu);
        this.add(labmima);
        this.add(txtmima);
        this.add(btndianji);
        btndianji.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                new StudentFrame();}
        } );
        setVisible(true);
    }
}
